import request from "@/utils/request";

// 获取仓库列表
export function getWarehouseListApi(query, data) {
  return request({
    url: "/system/warehouse/list",
    method: "post",
    params: query,
    data,
  });
}

// 新增仓库信息
export function addWarehouseApi(data) {
  return request({
    url: "/system/warehouse/add",
    method: "post",
    data,
  });
}

// 编辑仓库信息
export function editWarehouseApi(data) {
  return request({
    url: "/system/warehouse/edit",
    method: "post",
    data,
  });
}

// 获取仓库详情
export function getWarehouseApi(warehouseId) {
  return request({
    url: "/system/warehouse/getInfo",
    method: "get",
    params: { warehouseId },
  });
}

// 删除仓库
export function deleteWarehouseApi(warehouseId) {
    return request({
      url: `/system/warehouse/del`,
      method: "get",
      params: { warehouseId },
    });
  }

  // 获取人员
export function getUserList() {
    return request({
      url: `/system/warehouse/selectUserInfo`,
      method: "get",
    });
  }
 